package com.globallogic.dailyplanner.service.impl;

import org.springframework.security.core.Authentication;
import org.springframework.security.core.context.SecurityContextHolder;
import org.springframework.stereotype.Service;

import com.globallogic.dailyplanner.service.LoginService;

@Service
public class LoginServiceImpl implements LoginService{
	
	@Override
	public String getAuthUsername(){
		Authentication auth = SecurityContextHolder.getContext().getAuthentication();
		return auth.getName();
	}
}
